package com.blockchain.nodes.manager.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.blockchain.nodes.common.base.BaseEntity;
import com.fasterxml.jackson.annotation.JsonFormat;

import java.util.Date;

/**
 * 交易流水表 t_transaction_flow
 * 
 * @author Gene Max
 * @date 2019-03-08
 */
public class TransactionFlow extends BaseEntity
{
	private static final long serialVersionUID = 1L;
	
	/** 主键 */
	private Long id;
	/** 账户id */
	private Long accountId;
	/** 账单类型 1链资产转出 2链资产接收 3 快积分转出 4 快积分接收 */
	private String billType;
	/** 交易金额 */
	private Long amount;
	/**  1 快积分 2区块积分 */
	private String coinType;
	/** 收支方向：0-支出；1-收入 */
	private String direction;
	/** 交易发生时间 */
	@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss")
	private Date transTime;
	/** 交易状态
 1 等待确认
 2 已成功
 3 失败 4 已退款 */
	private String status;
	/** 交易手续费 */
	private Long transFee;
	/** 备注 */
	private String remarks;
	
	private String transType;
	
	private String transHash;
	private String turnInWallet;
	private String turnOutWallet;
	private String nodeId;
	private Long beforeAmount;
	private Long afterAmount;
	private String mobile;
	private String tAmount;

	public void setId(Long id) 
	{
		this.id = id;
	}

	public Long getId() 
	{
		return id;
	}
	public void setAccountId(Long accountId) 
	{
		this.accountId = accountId;
	}

	public Long getAccountId() 
	{
		return accountId;
	}
	public void setBillType(String billType) 
	{
		this.billType = billType;
	}

	public String getBillType() 
	{
		return billType;
	}
	public void setAmount(Long amount) 
	{
		this.amount = amount;
	}

	public Long getAmount() 
	{
		return amount;
	}
	public void setCoinType(String coinType) 
	{
		this.coinType = coinType;
	}

	public String getCoinType() 
	{
		return coinType;
	}
	public void setDirection(String direction) 
	{
		this.direction = direction;
	}

	public String getDirection() 
	{
		return direction;
	}
	public void setTransTime(Date transTime) 
	{
		this.transTime = transTime;
	}

	public Date getTransTime() 
	{
		return transTime;
	}
	public void setStatus(String status) 
	{
		this.status = status;
	}

	public String getStatus() 
	{
		return status;
	}
	public void setTransFee(Long transFee) 
	{
		this.transFee = transFee;
	}

	public Long getTransFee() 
	{
		return transFee;
	}
	public void setRemarks(String remarks) 
	{
		this.remarks = remarks;
	}

	public String getRemarks() 
	{
		return remarks;
	}
	
	

    public String getTransType() {
		return transType;
	}

	public void setTransType(String transType) {
		this.transType = transType;
	}

	public String getTransHash() {
		return transHash;
	}

	public void setTransHash(String transHash) {
		this.transHash = transHash;
	}

	public String getTurnInWallet() {
		return turnInWallet;
	}

	public void setTurnInWallet(String turnInWallet) {
		this.turnInWallet = turnInWallet;
	}

	public String getTurnOutWallet() {
		return turnOutWallet;
	}

	public void setTurnOutWallet(String turnOutWallet) {
		this.turnOutWallet = turnOutWallet;
	}

	public String getNodeId() {
		return nodeId;
	}

	public void setNodeId(String nodeId) {
		this.nodeId = nodeId;
	}

	public Long getBeforeAmount() {
		return beforeAmount;
	}

	public void setBeforeAmount(Long beforeAmount) {
		this.beforeAmount = beforeAmount;
	}

	public Long getAfterAmount() {
		return afterAmount;
	}

	public void setAfterAmount(Long afterAmount) {
		this.afterAmount = afterAmount;
	}
	
	

	public String getMobile() {
		return mobile;
	}

	public void setMobile(String mobile) {
		this.mobile = mobile;
	}
	
	

	public String gettAmount() {
		return tAmount;
	}

	public void settAmount(String tAmount) {
		this.tAmount = tAmount;
	}

	public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("accountId", getAccountId())
            .append("billType", getBillType())
            .append("amount", getAmount())
            .append("coinType", getCoinType())
            .append("direction", getDirection())
            .append("transTime", getTransTime())
            .append("status", getStatus())
            .append("transFee", getTransFee())
            .append("remarks", getRemarks())
            .toString();
    }
}
